<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>三角形</title>
  <style>
    .angle {
      margin: 80px;
      width:0px;
      height:0px;
      border-top:100px solid red;
      border-right:100px solid black;
      border-bottom:100px solid blue;
      border-left:100px solid green;
    }
    .angle-1{
      margin: 100px;
      width:100px;
      height:100px;
      border-top:5px solid red;
      border-left:5px solid red;
      transform: rotate(45deg);
      position: relative;
      
    }
  </style>
</head>
<body>
  <div class="angle"></div>

  <div class="angle-1"></div>
</body>
</html>